package abq2.jic.jic.plugin.operate.fastShowAI;

import kd.bos.base.AbstractBasePlugIn;
import kd.bos.form.events.BeforeDoOperationEventArgs;
import kd.bos.form.operate.FormOperate;
import kd.bos.servicehelper.DispatchServiceHelper;
import kd.sdk.plugin.Plugin;

import java.util.HashMap;

/**
 * 基础资料插件
 */
public class FastShowSchedule extends AbstractBasePlugIn implements Plugin {
    @Override
    public void beforeDoOperation(BeforeDoOperationEventArgs e) {
        super.beforeDoOperation(e);
        String operateKey = ((FormOperate) e.getSource()).getOperateKey();
        if (operateKey.equals("showai")){
            String pageId = this.getView().getMainView().getPageId();
            //GPT任务的id编码
            Object pkValue = Long.parseLong("1954601799130295296");
            DispatchServiceHelper.invokeBizService("ai", "gai", "GaiService","selectProcessInSideBar",pkValue,pageId,"请输入你的日任务内容");
        }
    }
}